/**
 * 
 */
package at.ac.tuwien.swa075.telco.hlr.dao.entity;

import java.util.HashSet;
import java.util.Set;

import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.OneToMany;
import javax.persistence.Table;


/**
 * @author vovmj01
 *
 */
@Entity
@Table (name="customer")
public class CustomerEntity {
	
	@Id
	@GeneratedValue(strategy=GenerationType.AUTO)
	private int id;
	
	private String firstname;
	private String lastname;
	private String birthDate;
	private String adress;
	private String city;
	private String country;
	
	@OneToMany(mappedBy="customer",cascade = CascadeType.ALL)
	private Set<SubscriptionEntity> subscriptions = new HashSet<SubscriptionEntity>();

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#getAdress()
	 */
	public String getAdress() {
		return adress;
	}

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#setAdress(java.lang.String)
	 */
	public void setAdress(String adress) {
		this.adress = adress;
	}

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#getBrithDate()
	 */
	public String getBirthDate() {
		return birthDate;
	}

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#setBrithDate(java.util.Date)
	 */
	public void setBirthDate(String brithDate) {
		this.birthDate = brithDate;
	}

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#getCity()
	 */
	public String getCity() {
		return city;
	}

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#setCity(java.lang.String)
	 */
	public void setCity(String city) {
		this.city = city;
	}

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#getCountry()
	 */
	public String getCountry() {
		return country;
	}

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#setCountry(java.lang.String)
	 */
	public void setCountry(String country) {
		this.country = country;
	}

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#getFirstname()
	 */
	public String getFirstname() {
		return firstname;
	}

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#setFirstname(java.lang.String)
	 */
	public void setFirstname(String firstname) {
		this.firstname = firstname;
	}

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#getId()
	 */
	public int getId() {
		return id;
	}

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#setId(int)
	 */
	public void setId(int id) {
		this.id = id;
	}

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#getLastname()
	 */
	public String getLastname() {
		return lastname;
	}

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#setLastname(java.lang.String)
	 */
	public void setLastname(String lastname) {
		this.lastname = lastname;
	}

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#getSubscriptions()
	 */
	public Set<SubscriptionEntity> getSubscriptions() {
		return subscriptions;
	}

	/* (non-Javadoc)
	 * @see at.ac.tuwien.swa075.telco.hlr.dao.entities.ICustomer#setSubscriptions(java.util.Set)
	 */
	public void setSubscriptions(Set<SubscriptionEntity> subscriptions) {
		this.subscriptions = subscriptions;
	}

}
